Intelligent sorting of time series data for improved contextual messaging

ABSTRACT

Systems for intelligent sorting of time series data for improved contextual messaging are included herein. An intelligent sorting server may receive time series data comprising a plurality of chat messages. The intelligent sorting server may determine a first order of the plurality of chat messages based on a chronologic order. The intelligent sorting server may use one or more machine learning classifiers to identify candidates for reordering the chat messages. The intelligent sorting server may generate a second order of the chat messages based on the identified candidates for reordering. Accordingly, the intelligent sorting server may present, to a client device, a transcript of the chat messages associated with the second order and an indication that at least one chat message has been repositioned.

CROSS-REFERENCE TO RELATED APPLICATIONS

The instant application claims priority to co-pending U.S. patentapplication Ser. No. 17/399,561, titled “Intelligent Sorting of TimeSeries Data for Improved Contextual Messaging,” and filed Aug. 11, 2021,the disclosure of which is hereby incorporated by reference in itsentirety.

FIELD OF USE

Aspects of the disclosure relate generally to data processing and morespecifically to the processing and management of big data.

BACKGROUND

In an electronic messaging system, a server may receive multiplemessages from a plurality of client devices. As the messages arrive atthe server, some messages may be delayed and certain messages may notarrive sequentially from a particular client. Conventional systems mayfail to recognize these out-of-order messages and still display themessages in chronological order. As a result, conventional systems maynot follow the natural flow of a conversation and cause confusion forusers trying to understand their chat messages.

Aspects described herein may address these and other problems, andgenerally improve the quality, efficiency, and speed of processing datato offer insights into conversational data so that users may makeinformed decisions.

SUMMARY

The following presents a simplified summary of various aspects describedherein. This summary is not an extensive overview, and is not intendedto identify key or critical elements or to delineate the scope of theclaims. The following summary merely presents some concepts in asimplified form as a prelude to the more detailed description providedbelow. Corresponding apparatus, systems, and computer-readable media arealso within the scope of the disclosure.

Systems as described herein may include features for intelligent sortingof time series data for improved contextual messaging. A server system(e.g. an intelligent sorting server) may receive time series dataincluding a plurality of chat messages from a plurality of clientdevices. Each chat message may have a timestamp that corresponds to thetime that it was transmitted to the server system. A first order of theplurality of chat messages may be determined based on a chronologicorder of the corresponding timestamps. The server system may use one ormore machine learning classifiers to identify candidates for reorderingthe chat messages based on, for example, a similarity score indicatingcontextual similarities between a pair of chat messages. The serversystem may generate a second order of the chat messages based on theidentified candidates for reordering. The server may provide, to aclient device, a transcript of the chat messages associated with thesecond order and an indication that at least one chat message has beenrepositioned.

These features, along with many others, are discussed in greater detailbelow.

BRIEF DESCRIPTION OF THE DRAWINGS

The present disclosure is described by way of example and not limited inthe accompanying figures in which like reference numerals indicatesimilar elements and in which:

FIG. 1 depicts an example of a system for intelligent sorting of timeseries data in which one or more aspects described herein may beimplemented;

FIG. 2 depicts an example of a computing device that may be used inimplementing one or more aspects of the disclosure in accordance withone or more illustrative aspects discussed herein;

FIG. 3 depicts an example deep neural network architecture for a modelaccording to one or more aspects of the disclosure;

FIG. 4 shows a flow chart of a process for intelligent sorting of timeseries data for improved contextual messaging according to one or moreaspects of the disclosure; and

FIGS. 5A-5B show example user interfaces displaying transcripts of thechat messages according to one or more aspects of the disclosure.

DETAILED DESCRIPTION

In the following description of the various embodiments, reference ismade to the accompanying drawings, which form a part hereof, and inwhich is shown by way of illustration various embodiments in whichaspects of the disclosure may be practiced. It is to be understood thatother embodiments may be utilized and structural and functionalmodifications may be made without departing from the scope of thepresent disclosure. Aspects of the disclosure are capable of otherembodiments and of being practiced or being carried out in various ways.In addition, it is to be understood that the phraseology and terminologyused herein are for the purpose of description and should not beregarded as limiting. Rather, the phrases and terms used herein are tobe given their broadest interpretation and meaning.

By way of introduction, aspects discussed herein may relate to methodsand techniques for intelligent sorting of time series data for improvedcontextual messaging. In an electronic messaging processing network, aserver system may use a first machine learning classifier to generatesimilarity scores for a plurality of chat messages. A similarity scoremay indicate a contextual similarity between a chat message and aprevious chat message. The server system may use a second machinelearning classifier to identify the candidates for reordering based onprobability scores. A probability score may indicate a likelihood that achat message is to be clustered with any previous chat message. Theserver may use the similarity scores generated by the first machinelearning classifier as inputs for the second machine learningclassifier. In addition to the similarity scores, the second machinelearning classifier may use the corresponding timestamps of the messagesand typing patterns of users as inputs. In an example, the first machinelearning classifier may be an unsupervised machine learning classifierand the second machine learning classifier may be a supervised machinelearning classifier.

In many aspects, the server system may assign a first weight associatedwith a timestamp difference between a chat message and a previous chatmessage. The server system may assign a second weight associated with asimilarity score between the chat message and the previous chat message.The server system may assign the first weight to be greater than thesecond weight. The server system may use the machine learning classifierto identify the candidates for reordering based on the first weight andthe second weight. The server system may assign a third weightassociated with a typing pattern for at least one sender of the chatmessage or the previous chat message. The third weight may be smallerthan the first weight and the second weight. The server system may usethe second machine learning classifier to identify the candidates forreordering based on the third weight.

In many aspects, the server system may determine a domain associatedwith the machine learning classifier. The server system may train thefirst machine learning classifier based on domain specific trainingdata.

Intelligent Sorting System

FIG. 1 shows an example of a system 100 where time series data such aschat messages may be sorted intelligently for improved contextualmessaging. The system 100 may include one or more user devices 110-120,at least one intelligent sorting server 130, at least one chat datastore 140, and/or at least one user pattern database 150 incommunication via a network 160. It will be appreciated that the networkconnections shown are illustrative and any means of establishing acommunications link between the computers may be used. The existence ofany of various network protocols such as TCP/IP, Ethernet, FTP, HTTP andthe like, and of various wireless communication technologies such asGSM, CDMA, WiFi, and LTE, is presumed, and the various computing devicesdescribed herein may be configured to communicate using any of thesenetwork protocols or technologies. Any of the devices and systemsdescribed herein may be implemented, in whole or in part, using one ormore computing devices described with respect to FIG. 2 .

User devices 110-120 may be any device that belongs to a customer of abusiness organization, such as a financial institution. The customersmay conduct transactions with the financial institution using userdevices 110-120. User devices 110-120 may also be any device thatbelongs to a user, such as a customer service agent, of the businessorganization. The customers or users may send chat messages to thefinancial institution using user devices 110-120 to engage in a varietyof activities. For example, a customer may send chat messages to acustomer service agent inquiring about charges on a credit card. Thecustomer may make an online payment using user devices 110-120 and chatwith the customer service agent for assistance. A customer may send chatmessages to a customer service agent reporting fraudulent activitiesrelated to an account. User devices 110-120 may receive a transactionsummary related to previously conducted purchases through a chat UI withthe customer service agent. In some examples, user devices 110 may alsoengage in chat sessions with user devices 120. In other examples, userdevices 110 may be used by customers of a business organization and userdevices 120 may be used by customer service agents in the businessorganization.

The chat sessions may include various chat messages and each chatmessage may correspond to a timestamp (e.g. the timestamp when themessage was created in a local computer time of user devices 110-120).The chat messages may arrive at a target user device or a financialinstitution, such as a server (e.g. intelligent sorting server 130) atvarious times. However, a latency between a user device and a server maycause messages to be delayed and the natural flow of the conversationbetween a user and a customer service agent may be broken up, that isout of order. As messages arrive at the server, the messages may notarrive sequentially from a single user device. For example, somemessages may be delayed more than other messages, or certain messagesmay be swapped in their orders. Typing speed of the customers or theagents may also affect the order of the messages being displayed on thechat UI of user devices 110-120. As a result, some messages may bedisplayed on the chat UI in a chronological order, but may not makelogic sense. User devices 110-120 may include client agents orapplications that may monitor inputs from the customers or the customerservice agents, such as their typing speeds, and their patterns inprevious chat messages, such as key words they used in query messages.User devices 110-120 may send the typing speeds and user patterns tointelligent sorting server 130 for processing.

Intelligent sorting server 130 may receive from a plurality of userdevices 110-120, time series data including a plurality of chatmessages. Each chat message has a timestamp corresponding to the timethe message was transmitted to intelligent sorting server 130.Intelligent sorting server 130 may determine that the chat message isassociated with a chat session between a user and a customer serviceagent. Intelligent sorting server 130 may determine that the chatmessage is associated with a chat session between two users. Intelligentsorting server 130 may determine that a plurality of chat messages isassociated with a particular user. Intelligent sorting server 130 mayreceive typing speeds and user patterns from user devices 110-120 andstore the relevant information in user pattern database 150.

Intelligent sorting server 130 may attempt to preprocess the raw timeseries data comprising the chat messages. The chat messages may be in anon-standard format, such as a non-structured form, or in the form of aline of data, or in a text format. The chat messages may be convertedinto a standard format, such as a JSON or XML format. Intelligentsorting server 130 may determine a first order of these chat messagesbased on a chronologic order of the corresponding timestamps. Forexample, a timestamp of the chat message may reflect a local computertime of a user device when the message was transmitted to theintelligent sorting server 130.

Intelligent sorting server 130 may use one or more machine learningclassifiers to identify candidates for reordering the chat messages.Intelligent sorting server 130 may use a first machine learningclassifier to generate similarity scores for the chat messages that areassociated with a chat session between a user and a customer serviceagent, or a chat session between two users. Based on the chronologicorder, intelligent sorting server 130 may determine a chat message and aprevious chat message relative to the chat message. Intelligent sortingserver 130 may determine a similarity score indicating a contextualsimilarity between the chat message and the previous chat message. Forexample, intelligent sorting server 130 may use training data includingtagged time series data indicating a plurality of contextually similarchat messages to train the first machine learning classifier.Intelligent sorting server 130 may provide, as input to the trainedfirst machine learning model, the chat message and the previous chatmessage. Intelligent sorting server 130 may receive, as output from thetrained first machine learning model, a similarity score indicating adegree of similarity between the chat message and the previous chatmessage.

Intelligent sorting server 130 may use a second machine learningclassifier to identify chat message candidates for reordering. Forexample, intelligent sorting server 130 may use tagged chat messagesindicating identified candidate messages for reordering to train thesecond machine learning classifier. Intelligent sorting server 130 mayprovide, for example, the chat messages, their timestamps or timeperiods between a pair of chat messages, their similarity scores, usertyping patterns, query indications (e.g. a question mark or languageindicating a query in the chat messages) to the trained second machinelearning classifier. Intelligent sorting server 130 may receive, asoutput from the trained second machine learning model, a probabilityscore indicating a likelihood that a particular chat message may be acandidate for reordering.

Intelligent sorting server 130 may reorder the chat messages based onthe identified one or more candidates for reordering, and generate asecond order of the chat messages. The second order may be based on achronologic order, or a contextual order, and or both. Intelligentsorting server 130 may provide, to a client device, a transcript of thechat messages associated with the second order and an indication that atleast one chat message has been repositioned.

Chat data store 140 may store time series data including chat messagesfrom various user devices 110-120. The chat messages may bepre-processed in a standard format. The chat messages may bepre-processed to identify query indications such as a question mark orlanguage indicating a query. The pre-processed chat messages may bestored in chat data store 140. Chat data store 140 may store thetimestamps, time periods associated with a pair of chat messages, and/orthe query indications with the chat messages. Chat data store 140 maystore training data such as tagged time series data including aplurality of contextually similar chat messages and their correspondingsimilarity scores. Chat data store 140 may store training data includingtagged chat messages indicating pre-identified candidate messages forreordering. After intelligent sorting server 130 determines thesimilarities scores, the probability scores, and the candidate chatmessages for reordering, it may store them in chat data score 140.

User pattern database 150 may store user information related to users orcustomer service agents, such as indications of their typing speeds, andother user patterns, for example, the key words the user may use forindicating a query in the chat messages. The user pattern informationmay be gleaned by user devices 110-120 and processed by intelligentsorting server 130. Intelligent sorting server 130 may store the userpattern information in user pattern database 150. As new chat messagesarrive in intelligent sorting server 130, the user pattern informationmay be enhanced and continue to be stored in user pattern database 150.

User devices 110-120, intelligent sorting server 130, chat data store140, and/or user pattern database 150 may be associated with aparticular authentication session. Intelligent sorting server 130 mayreceive, process, and/or store a variety of chat messages, and userpattern information, and/or send transcripts with reordered messages touser devices 110-120 as described herein. However, it should be notedthat any device in system 100 may perform any of the processes and/orstore any data as described herein. Some or all of the data describedherein may be stored using one or more databases. Databases may include,but are not limited to relational databases, hierarchical databases,distributed databases, in-memory databases, flat file databases, XMLdatabases, NoSQL databases, graph databases, and/or a combinationthereof. Network 160 may include a local area network (LAN), a wide areanetwork (WAN), a wireless telecommunications network, and/or any othercommunication network or combination thereof.

The data transferred to and from various computing devices in system 100may include secure and sensitive data, such as confidential documents,customer personally identifiable information, and account data.Therefore, it may be desirable to protect transmissions of such datausing secure network protocols and encryption, and/or to protect theintegrity of the data when stored on the various computing devices. Afile-based integration scheme or a service-based integration scheme maybe utilized for transmitting data between the various computing devices.Data may be transmitted using various network communication protocols.Secure data transmission protocols and/or encryption may be used in filetransfers to protect the integrity of the data such as, but not limitedto, File Transfer Protocol (FTP), Secure File Transfer Protocol (SFTP),and/or Pretty Good Privacy (PGP) encryption. In many embodiments, one ormore web services may be implemented within the various computingdevices. Web services may be accessed by authorized external devices andusers to support input, extraction, and manipulation of data between thevarious computing devices in the system 100. Web services built tosupport a personalized display system may be cross-domain and/orcross-platform, and may be built for enterprise use. Data may betransmitted using the Secure Sockets Layer (SSL) or Transport LayerSecurity (TLS) protocol to provide secure connections between thecomputing devices. Web services may be implemented using the WS-Securitystandard, providing for secure SOAP messages using XML encryption.Specialized hardware may be used to provide secure web services. Securenetwork appliances may include built-in features such ashardware-accelerated SSL and HTTPS, WS-Security, and/or firewalls. Suchspecialized hardware may be installed and configured in the system 100in front of one or more computing devices such that any external devicesmay communicate directly with the specialized hardware.

Computing Devices

Turning now to FIG. 2 , a computing device 200 that may be used with oneor more of the systems 100 is described. The computing device 200 mayinclude a processor 203 for controlling overall operation of thecomputing device 200 and its associated components, including RAM 205,ROM 207, input/output device 209, communication interface 211, and/ormemory 215. A data bus may interconnect processor(s) 203, RAM 205, ROM207, memory 215, I/O device 209, and/or communication interface 211. Insome embodiments, computing device 200 may represent, be incorporatedin, and/or include various devices such as a desktop computer, acomputer server, a mobile device, such as a laptop computer, a tabletcomputer, a smart phone, any other types of mobile computing devices,and the like, and/or any other type of data processing device.

Input/output (I/O) device 209 may include a microphone, keypad, touchscreen, and/or stylus through which a user of the computing device 200may provide input, and may also include one or more of a speaker forproviding audio output and a video display device for providing textual,audiovisual, and/or graphical output. Software may be stored withinmemory 215 to provide instructions to processor 203 allowing computingdevice 200 to perform various actions. Memory 215 may store softwareused by the computing device 200, such as an operating system 217,application programs 219, and/or an associated internal database 221.The various hardware memory units in memory 215 may include volatile andnonvolatile media, removable and non-removable media implemented in anymethod or technology for storage of information such ascomputer-readable instructions, data structures, program modules, orother data. Memory 215 may include one or more physical persistentmemory devices and/or one or more non-persistent memory devices. Memory215 may include, but is not limited to, random access memory (RAM) 205,read only memory (ROM) 207, electronically erasable programmable readonly memory (EEPROM), flash memory or other memory technology, opticaldisk storage, magnetic cassettes, magnetic tape, magnetic disk storageor other magnetic storage devices, or any other medium that may be usedto store the desired information and that may be accessed by processor203.

Communication interface 211 may include one or more transceivers,digital signal processors, and/or additional circuitry and software forcommunicating via any network, wired or wireless, using any protocol asdescribed herein.

Processor 203 may include a single central processing unit (CPU), whichmay be a single-core or multi-core processor, or may include multipleCPUs. Processor(s) 203 and associated components may allow the computingdevice 200 to execute a series of computer-readable instructions toperform some or all of the processes described herein. Although notshown in FIG. 2 , various elements within memory 215 or other componentsin computing device 200, may include one or more caches including, butnot limited to, CPU caches used by the processor 203, page caches usedby the operating system 217, disk caches of a hard drive, and/ordatabase caches used to cache content from database 221. For embodimentsincluding a CPU cache, the CPU cache may be used by one or moreprocessors 203 to reduce memory latency and access time. A processor 203may retrieve data from or write data to the CPU cache rather thanreading/writing to memory 215, which may improve the speed of theseoperations. In some examples, a database cache may be created in whichcertain data from a database 221 is cached in a separate smallerdatabase in a memory separate from the database, such as in RAM 205 oron a separate computing device. For instance, in a multi-tieredapplication, a database cache on an application server may reduce dataretrieval and data manipulation time by not needing to communicate overa network with a back-end database server. These types of caches andothers may be included in various embodiments, and may provide potentialadvantages in certain implementations of devices, systems, and methodsdescribed herein, such as faster response times and less dependence onnetwork conditions when transmitting and receiving data.

Although various components of computing device 200 are describedseparately, functionality of the various components may be combinedand/or performed by a single component and/or multiple computing devicesin communication without departing from the invention.

Deep Neural Network Architecture

FIG. 3 illustrates an example deep neural network architecture 300. Sucha deep neural network architecture may be implemented by a computingdevice 200 shown in FIG. 2 . That said, the architecture depicted inFIG. 3 need not be performed on a single computing device, and might beperformed by, e.g., a plurality of computers. An artificial neuralnetwork may be a collection of connected nodes, with the nodes andconnections each having assigned weights used to generate predictions.Each node in the artificial neural network may receive input andgenerate an output signal. The output of a node in the artificial neuralnetwork may be a function of its inputs and the weights associated withthe edges. Ultimately, the trained model may be provided with inputbeyond the training set and used to generate predictions regarding thelikely results. Artificial neural networks may have many applications,including object classification, image recognition, speech recognition,natural language processing, text recognition, regression analysis,behavior modeling, and others.

An artificial neural network may have an input layer 310, one or morehidden layers 320, and an output layer 330. A deep neural network, asused herein, may be an artificial network that has more than one hiddenlayer. Illustrated network architecture 300 is depicted with threehidden layers, and thus may be considered a deep neural network. Thenumber of hidden layers employed in deep neural network 300 may varybased on the particular application and/or problem domain. For example,a network model used for image recognition may have a different numberof hidden layers than a network used for speech recognition. Similarly,the number of input and/or output nodes may vary based on theapplication. Many types of deep neural networks are used in practice,such as convolutional neural networks, recurrent neural networks, feedforward neural networks, combinations thereof, and others.

During the model training process, the weights of each connection and/ornode may be adjusted in a learning process as the model adapts togenerate more accurate predictions on a training set. The weightsassigned to each connection and/or node may be referred to as the modelparameters. The model may be initialized with a random or white noiseset of initial model parameters. The model parameters may then beiteratively adjusted using, for example, stochastic gradient descentalgorithms that seek to minimize errors in the model.

Intelligent Sorting Chat Messages

The intelligent sorting system may process raw time series data, examinethe context of the chat messages and cluster similar messages togetherif their timestamps fall within a specific time range (i.e., in whichthey are relatively close in time to each other). The intelligentsorting system may implement one or more machine learning classifiers toconsider factors such as timestamps, contextual similarities, and usertyping speeds to identify candidates for reordering the messages. Theintelligent sorting system may implement a layer of a feedback loop whenthe reordered chat messages are displayed to users for their feedback asto whether the reordered messages follows a logic of conversation. Assuch, the time series data may be transformed into visualrepresentations of the chat messages with indications of repositionedmessages, which may resonate with the users to facilitate communicationand decision making.

FIG. 4 shows a flow chart of a process for intelligent sorting timeseries data for improved messaging according to one or more aspects ofthe disclosure. Some or all the steps of process 400 may be performedusing one or more computing devices or deep neural networks as describedherein. In a variety of embodiments, some or all the steps describedbelow may be combined and/or divided into sub-steps as appropriate.

At step 410, an intelligent sorting server may receive time series datacomprising chat messages from user devices. For example, the chatmessages may be between a user and a customer service agent. Each chatmessage may have a timestamp indicating a local computer time of theclient device when the chat message was transmitted to the intelligentsorting server. For example, a customer service agent may send amessage: “Hi there, my name is Joe. How can I help you today?” attimestamp T1. The customer may respond with the message: “Hi Joe. I'dlike to report fraud on my card” at timestamp T2. T1 may correspond to alocal computer time on a user device used by the agent and T2 maycorrespond to a local computer time on a user device used by thecustomer. T1 and T2 may correspond to the timestamps when the chatmessages were transmitted to the intelligent sorting server. T1 and T2may also correspond to the timestamps that the user or the agent startedto type the messages on their respective user devices. The customerservice agent may send a message at timestamp T3: “Can you provide yourCVC2 number?” The customer may send a message at timestamp T4: “123.”The agent may send a message at timestamp T5: “This is the 3 digits onthe back of your card.” The agent may send a message at timestamp T6:“Thank you.”

In a variety of embodiments, the user devices may have a chat agent or achat application installed to monitor and capture input behavior of theusers in real time. For example, the user devices may capture when auser starts typing a message and send the corresponding timestamp withthe message to the intelligent sorting server. The user devices may alsocapture user patterns such as the typing speed of a user and send theuser pattern information to the intelligent sorting server.

In a variety of embodiments, there may be latency between the clientdevices and the intelligent sorting server. The display of some messageson the user devices may be delayed and the flow of the conversation maybe broken up, that is out of order. As messages arrive at theintelligent sorting server, the messages may not arrive sequentiallyfrom a single user device. There are cases that certain messages may bedelayed more than other messages, or the messages may be swapped intheir orders. Although a user may start typing a message in response toan agent's inquiry, the user may type at a slow speed, which maycontribute to the delay of the user's message and such message mayarrive at the intelligent sorting server out of order. In some examples,the user and the agent may start typing simultaneously, the user'smessage “123” may arrive at T4 faster than the agent's message “This isthe 3 digits on the back of your card” at T5, because the user's messageis shorter and may be transmitted quicker. Such out of order messagesmay break the logical flow of the messages and cause confusion in thechat log in real time or at a later time when the chat log may bereviewed.

In a variety of embodiments, the intelligent sorting server maypre-process the chat messages. For example, the intelligent sortingserver may receive the time series data in non-standard format, such asa non-structured format or a line of data. The intelligent server maypre-process the chat messages and convert them into a standard formatsuch as JSON or XML format. The chat messages may be pre-processed toidentify query indications such as a question mark. The intelligentsorting server may use a natural language process (NLP) to identifykeywords or language indicating a query or related to a specific domain.A domain may include, for example, a generic chat domain or a personalfinance related domain. For example, based on the key words “fraud,”“card,” and “CVC2,” the intelligent sorting server may determine thechat messages at T1-T6 relate to a personal finance domain.

At step 412, the intelligent sorting server may determine a first orderof the chat messages based on a chronologic order of the correspondingtimestamps. For example, the first order may be determined based on thetimestamps T1-T6. As discussed above, the chronologic order of the chatmessages may not reflect the logic flow of the conversation between thecustomer and the agent, and certain messages may be out of order.

At step 414, the intelligent sorting server may use one or more machinelearning classifiers to identify candidates for reordering the chatmessages. In a variety of embodiments, the intelligent sorting servermay examine the timestamps of the messages originated from a single userdevice. If the user started typing a message before a future messagecame through, the message may more likely be associated with a previousmessage. As such, the intelligent sorting server may examine inputbehavior of the user in real time, which may be captured in the chatapplication or chat agent on the user devices.

In a variety of embodiments, the intelligent sorting server may examinethe context of the chat messages, using contextual clues within the chatmessages. For example, if the message contains a question mark, the useris likely waiting for a response after sending the chat message. As aresult, the next message originated from the same user may be lesslikely to be associated with the previous message sent by the user. Inanother example, if the message contains a question mark, the user mayfurther send a message to offer an explanation related to the previousquestion. As a result, the next message originated from the same usermay more likely be associated with the previous message sent by theuser.

The intelligent sorting server may use a first machine learningclassifier to cluster the chat messages based on similarity scores ofthe messages. A similarity score may indicate a contextual similaritybetween a chat message and a previous chat message. The intelligentsorting server may determine a domain associated with the machinelearning classifier. The intelligent sorting server may train the firstmachine learning classifier based on domain specific training data. Forexample, the intelligent sorting server may use training data includingtagged personal finance time series data indicating a plurality ofcontextually similar chat messages to train the first machine learningclassifier. Based on the keywords in the chat messages, the intelligentsorting server may determine that the messages relate to a personalfinance domain. The first machine learning classifier may be trained torecognize keywords related to personal finance domain. For example, ifthe chat message at T3 is “a Can you provide your CVC2 number,” thefirst machine learning classifier may recognize that the CVC2 numbercontains three digits. The message at T5 is “this is the 3 digits on theback of your card.” The first machine learning classifier may determineit is highly likely that the T3 and T5 messages are related and mayincrease the similarity score so that they may be allocated in the samecluster.

Intelligent sorting server may provide, as input to the trained firstmachine learning model, the chat message and the previous chat message.Intelligent sorting server may receive, as output from the trained firstmachine learning classifier, a similarity score indicating a degree ofsimilarity between the chat message and the previous chat message. Forexample, the first machine learning classifier may determine a firstsimilarity score S1 between the chat message at T3 “Can you provide yourCVC2 number” and the chat message at T4 “123.” The first machinelearning classifier may determine a second similarity score S2 betweenthe chat message at T3 “Can you provide your CVC2 number” and the chatmessage at T5 “this is the 3 digits on the back of your card.” Theintelligent sorting server may determine that S2 is greater than S1. Ifthe difference between S2 and S1 has reached a threshold value (e.g.50%), this may be an indication that the messages at T3 and T5 belong tothe same cluster. In a variety of embodiments, the first machinelearning classifier may be an unsupervised machine learning classifier.

The intelligent sorting server may use a second machine learningclassifier to identify the candidates for reordering based onprobability scores. A probability score may indicate a likelihood thatthe chat message is to be clustered together with a previous chatmessage. The server may use the similarity scores generated by the firstmachine learning classifier as an input for the second machine learningclassifier. The second machine learning classifier may also use otherinputs such as the corresponding timestamps of the messages and typingpatterns. For example, intelligent sorting server 130 may use taggedchat messages indicating identified candidate messages for reordering totrain the second machine learning classifier. Intelligent sorting server130 may provide, for example, the chat messages, their timestamps ortime periods between a pair of messages, their similarity scores, usertyping patterns, and/or query indications (e.g. a question mark orlanguage indicating a query in the chat messages) to the trained secondmachine learning classifier. Intelligent sorting server 130 may receive,as output from the trained second machine learning model, a probabilityscore indicating a likelihood that a particular chat message may be acandidate for reordering. For example, the second machine learning modelmay determine that the messages at T3 and T5 have a high probability(e.g. 90%) to be clustered together and the message at T5 may be acandidate for reordering.

In a variety of embodiments, the intelligent sorting server may assign afirst weight W1 associated with a timestamp difference between a chatmessage (e.g. message at T5) and a previous chat message (e.g. messageat T3). The timestamp difference may be, for example, a differencebetween T5 and T3. The intelligent sorting server may assign a secondweight W2 associated with a similarity score between the chat messageand the previous chat message. The first weight W1 may be greater thanthe second weight W2. The intelligent sorting server may use the machinelearning classifier to identify the candidates for reordering based onthe first weight W1 and the second weight W2.

The intelligent sorting server may assign a third weight W3 associatedwith a typing pattern for at least one sender of the chat message or theprevious chat message. The typing pattern may be a difference in thetyping speeds between a customer and a customer service agent. The thirdweight W3 may be smaller than the first weight W1 and the second weightW2. The intelligent sorting server may use the second machine learningclassifier to identify the candidates for reordering based on W1-W3. Assuch, the intelligent sorting server may adjust the weights on variousparameters. The intelligent sorting server may assign a greater weightto the timestamps. For example, if two messages have a medium similarityscore (e.g. 60%), and the timestamps indicates they are very far apart(e.g. more than 5 seconds), these two messages may not be clusteredtogether. If two messages have a high similarity score (e.g. 85%), andthe timestamps indicate they are not far apart (e.g. 1 second), thesetwo messages may be clustered together. In another example, if twomessages have a very high similarity score (e.g. 99%), and thetimestamps indicates they are very far apart (e.g. more than 5 seconds),these two messages may still be clustered together. In another example,the timestamps may be a determinative factor. If two messages are veryfar apart (e.g. more than 5 seconds), these two messages may not beclustered together, even though they have a very high similarity score(e.g. 99%).

The second machine learning model may be a supervised model. Forexample, during the training process, the intelligent sorting model maypresent the messages in a chronological order to the user for feedback.The user may confirm whether such order makes sense based on the logicflow of the conversation. FIG. 5A shows an example user interfacedisplaying a transcript of chat messages according to one or moreaspects of the disclosure. The transcript may be based on a chronologicorder of the chat messages with timestamps T1-T6 in screen 510 of a userdevice 500. The display may provide options for user to confirm whetherthis chronologic order of messages makes sense to the user. The user maychoose “Yes” to confirm or “No” to reject such order. Likewise, afterthe messages have been re-ordered, the intelligent sorting model maypresent the reordered messages to the user for feedback. The user mayconfirm whether the newly re-ordered messages make better sense than themessages in the chronologic order.

In a variety of embodiments, the intelligent sorting server mayimplement a two-stage model. The intelligent sorting machine may firstexamine the similarity of two messages from the content perspective. Theintelligent sorting server may use the output (e.g. similarity scores)from the first stage as an input to the second stage. The second stagemay consider other characteristics of the messages (e.g. timestamps,time differences, user patterns, query indications) on identifyingcandidates for reordering. Based on the identified candidates, theintelligent sorting server may determine whether any messages may beswapped or whether the messages may be clustered differently from theirchronologic order.

At step 416, the intelligent sorting server may determine a second orderof the chat messages based on the identified candidates for reordering.The second order may be different from the chronologic order, if atleast one candidate has been identified for reordering.

At step 418, the intelligent sorting server may provide, to a clientdevice, a transcript of the chat messages associated in the secondorder. The intelligent sorting server may also present an indicationthat at least one chat message has been repositioned. FIG. 5B showsexample user interfaces displaying reordered chat messages according toone or more aspects of the disclosure. FIG. 5B displays a transcript ofchat messages on a user device 500. The transcript may be displayed tothe user in real time.

With respect to FIG. 5B, display screen 520 of user device 500 maydisplay, for example, six chat messages between a customer and acustomer service agent. The fourth message “123” at T4 from the customerhas been greyed out, indicating this message has been relocated to a newposition after T5. In its new position between T5 and T6, the message“123” at T4 has been highlighted, indicating this message has beenrelocated to this new position. The display may also include anindication such as a “flag” to further indicate the repositioning of themessage at T4. It should be noted that any indication can be displayedin accordance with various aspects of the disclosure.

One or more aspects discussed herein may be embodied in computer-usableor readable data and/or computer-executable instructions, such as in oneor more program modules, executed by one or more computers or otherdevices as described herein. Generally, program modules includeroutines, programs, objects, components, data structures, and the likethat perform particular tasks or implement particular abstract datatypes when executed by a processor in a computer or other device. Themodules may be written in a source code programming language that issubsequently compiled for execution, or may be written in a scriptinglanguage such as (but not limited to) HTML or XML. The computerexecutable instructions may be stored on a computer readable medium suchas a hard disk, optical disk, removable storage media, solid-statememory, RAM, and the like. As will be appreciated by one of skill in theart, the functionality of the program modules may be combined ordistributed as desired in various embodiments. In addition, thefunctionality may be embodied in whole or in part in firmware orhardware equivalents such as integrated circuits, field programmablegate arrays (FPGA), and the like. Particular data structures may be usedto more effectively implement one or more aspects discussed herein, andsuch data structures are contemplated within the scope of computerexecutable instructions and computer-usable data described herein.Various aspects discussed herein may be embodied as a method, acomputing device, a system, and/or a computer program product.

Although the present invention has been described in certain specificaspects, many additional modifications and variations would be apparentto those skilled in the art. In particular, any of the various processesdescribed above may be performed in alternative sequences and/or inparallel (on different computing devices) in order to achieve similarresults in a manner that is more appropriate to the requirements of aspecific application. It is therefore to be understood that the presentinvention may be practiced otherwise than specifically described withoutdeparting from the scope and spirit of the present invention. Thus,embodiments of the present invention should be considered in allrespects as illustrative and not restrictive. Accordingly, the scope ofthe invention should be determined not by the embodiments illustrated,but by the appended claims and their equivalents.

What is claimed is:
 1. A computer-implemented method comprising:receiving, by a server, a plurality of chat messages, wherein each chatmessage includes a timestamp that indicates a time at which each chatmessage was transmitted to the server; determining a first chronologicorder of the timestamps; identifying, using a first machine learningclassifier, a chat message, in the plurality of chat messages, as acandidate for reordering based on: a timestamp difference between thechat message and a previous chat message; and a similarity score betweenthe chat message and the previous chat message; generating a secondorder of the plurality of chat messages based on the identifiedcandidates for reordering; and providing, to a client device, atranscript of the chat messages associated with the second order and anindication that at least one chat message has been repositioned.
 2. Thecomputer-implemented method of claim 1, wherein using the first machinelearning classifier comprises: assigning a first weight to the timestampdifference between the chat message and the previous chat message;assigning a second weight to the similarity score between the chatmessage and the previous chat message, wherein the first weight isgreater than the second weight; and identifying, using the first machinelearning classifier and based on the first weight and the second weight,the chat message as the candidate for reordering.
 3. Thecomputer-implemented method of claim 1, wherein using the first machinelearning classifier further comprises using typing patterns and queryindications as inputs for the first machine learning classifier.
 4. Thecomputer-implemented method of claim 2, further comprising: assigning athird weight to a typing pattern for at least one sender of the chatmessage or the previous chat message, wherein the third weight is lessthan the first weight and the second weight; and identifying, using thefirst machine learning classifier and based on the third weight, thechat message as the candidate for reordering.
 5. Thecomputer-implemented method of claim 1, wherein the similarity scoreindicates a contextual similarity between the chat message and theprevious chat message.
 6. The computer-implemented method of claim 1,further comprising: identifying, using a second machine learningclassifier and based on a probability score, candidates for reordering,wherein the probability score indicates a likelihood that the chatmessage is to be clustered together with the previous chat message. 7.The computer-implemented method of claim 6, wherein: the first machinelearning classifier comprises an unsupervised machine learningclassifier; and the second machine learning classifier comprises asupervised machine learning classifier.
 8. The computer-implementedmethod of claim 6, wherein using the first machine learning classifiercomprises using the similarity score generated by the first machinelearning classifier as an input for the second machine learningclassifier.
 9. The computer-implemented method of claim 8, wherein usingthe second machine learning classifier comprises receiving theprobability score as an output from the second machine learningclassifier.
 10. The computer-implemented method of claim 1, whereinusing the first machine learning classifier comprises: determining,based on one or more keywords in the plurality of chat messages, adomain associated with the first machine learning classifier; andtraining, based on domain specific training data, the first machinelearning classifier.
 11. An apparatus, comprising: one or moreprocessors; and memory storing instructions that, when executed by theone or more processors, cause the apparatus to: receive, by theapparatus, a plurality of chat messages, wherein each chat messageincludes a timestamp that indicates a time a which each chat message wastransmitted to the apparatus; determine a first chronologic order of thetimestamps; identify, using a first machine learning classifier, a chatmessage, in the plurality of chat messages, as a candidate forreordering based on: a timestamp difference between the chat message anda previous chat message; and a similarity score between the chat messageand the previous chat message; generate a second order of the pluralityof chat messages based on the identified candidates for reordering; andprovide, to a client device, a transcript of the chat messagesassociated with the second order and an indication that at least onechat message has been repositioned.
 12. The apparatus of claim 11,wherein the instructions, when executed by the one or more processors,cause the apparatus to use the first machine learning classifier by:assigning a first weight to the timestamp difference between the chatmessage and the previous chat message; assigning a second weight to thesimilarity score between the chat message and the previous chat message,wherein the first weight is greater than the second weight; andidentifying, using the first machine learning classifier and based onthe first weight and the second weight, the chat message as thecandidate for reordering.
 13. The apparatus of claim 11, wherein theinstructions, when executed by the one or more processors, cause theapparatus to use the first machine learning classifier by: using typingpatterns and query indications as inputs for the first machine learningclassifier.
 14. The apparatus of claim 12, wherein the instructions,when executed by the one or more processors, cause the apparatus to usethe first machine learning classifier by: assigning a third weight to atyping pattern for at least one sender of the chat message or theprevious chat message, wherein the third weight is less than the firstweight and the second weight; and identifying, using the first machinelearning classifier and based on the third weight, the chat message asthe candidate for reordering.
 15. The apparatus of claim 11, wherein thesimilarity score indicates a contextual similarity between the chatmessage and the previous chat message.
 16. The apparatus of claim 11,wherein the instructions, when executed by the one or more processors,cause the apparatus to: identifying, use a second machine learningclassifier and based on a probability score, candidates for reordering,wherein the probability score indicates a likelihood that the chatmessage is to be clustered together with the previous chat message. 17.The apparatus of claim 16, wherein the first machine learning classifiercomprises an unsupervised machine learning classifier and the secondmachine learning classifier comprises a supervised machine learningclassifier.
 18. The apparatus of claim 11, wherein the instructions,when executed by the one or more processors, cause the apparatus to usethe first machine learning classifier by: determining, based on one ormore keywords in the plurality of chat messages, a domain associatedwith the first machine learning classifier; and training the firstmachine learning classifier based on domain specific training data. 19.A non-transitory machine-readable medium storing instructions that, whenexecuted by one or more processors, cause the one or more processors toperform steps comprising: receiving a plurality of chat messages,wherein each chat message includes a timestamp that indicates a time awhich each chat message was transmitted to a server system; determininga first chronologic order of the timestamps; identifying, using a firstmachine learning classifier, a chat message, in the plurality of chatmessages, as a candidate for reordering based on: a timestamp differencebetween the chat message and a previous chat message; and a similarityscore between the chat message and the previous chat message; generatinga second order of the plurality of chat messages based on the identifiedcandidates for reordering; and providing, to a client device, atranscript of the chat messages associated with the second order and anindication that at least one chat message has been repositioned.
 20. Thenon-transitory machine-readable medium of claim 19, wherein theinstructions, when executed by the one or more processors, cause the oneor more processors to perform steps comprising: assigning a first weightto the timestamp difference between the chat message and the previouschat message; assigning a second weight to the similarity score betweenthe chat message and the previous chat message, wherein the first weightis greater than the second weight; and identifying, using the firstmachine learning classifier and based on the first weight and the secondweight, the chat message as the candidate for reordering.